//
//  ChoicenessViewModel.m
//  HappyNews
//
//  Created by lanou on 16/1/11.
//  Copyright © 2016年 BPWBANP. All rights reserved.
//

#import "ChoicenessViewModel.h"

@implementation ChoicenessViewModel
//- (instancetype)init
//{
//    self = [super init];
//    if (self) {
//          _bodyListArr = [NSMutableArray array];
//    }
//    
//    
//    return self;
//}
- (void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    if ([key isEqualToString:@"memberItem"]) {
        self.guid = value[@"guid"];
        self.shareUrl = value[@"shareUrl"];
    }
    
    if ([key isEqualToString:@"videoList"]) {
        for (NSMutableDictionary *dic in value) {
            self.title = dic[@"title"];
            self.image = dic[@"image"];
            self.playTime = dic[@"playTime"];
            NSDictionary *dic1 = dic[@"memberItem"];
            self.guid = dic1[@"guid"];
            self.duration = dic1[@"duration"];
            self.shareUrl = dic1[@"shareUrl"];
            
        }
    }
    
    
    
}
//- (void)setValue:(id)value forKey:(NSString *)key
//{
//    [super setValue:value forKey:key];
// 
//    if ([key isEqualToString:@"bodyList"]) {
//            for (NSMutableDictionary *oneDic in value) {
//            _bodyListModel = [[ChoicenessViewTwoModel alloc]init];
//            [_bodyListModel setValuesForKeysWithDictionary:oneDic];
//            [_bodyListArr addObject:_bodyListModel];
//        }
//
//    }
//}

@end
